<template>
  <div class="limits">
    <limitsList :limitData="limitData"></limitsList>
  </div>
</template>
<script>
import limitsList from "../../components/components_wxq/limitsList.vue";
import { roleLimit } from "../../utils/api/role";

export default {
  name: "limitsPage",
  components: {
    limitsList,
  },
  data() {
    return {
      id: null,
      limitData: null,
    };
  },
  methods: {
    setTable() {
      roleLimit(this.id).then((data) => {
        console.log(data);
        this.limitData = data.data.data.allMenu;
      });
    },
  },
  computed: {},
  watch: {},
  created() {
    console.log(this.$route.params);
    this.id = this.$route.params.id;
    this.setTable();
  },
};
</script>
<style lang="less" scoped></style>
